"""
join() 主动回收子进程，释放资源
start() 创建新进程前会检测之前是否已经有僵尸，有
"""
import os
from multiprocessing import Process
from time import sleep

def func():
    print("一大波僵尸正在逼近","--",os.getpid())

if __name__ == '__main__':
    jobs = []
    for i in range(5):
        p = Process(target=func)
        jobs.append(p)
        p.start()
        sleep(1)
    [i.join() for i in jobs]
    sleep(1000)